package com.techsoul.module.accounting.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.techsoul.module.accounting.pojo.entity.MaterialBuyPrice;
import com.techsoul.module.accounting.pojo.param.MaterialBuyPriceSearchParam;
import com.techsoul.module.accounting.pojo.vo.MaterialBuyPriceVo;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 供应商采购价格配置基础，用于配置价格，产生最后付款结算。Mapper接口
 * 
 * @author liuen
 * @date 2021-04-11
 */
public interface MaterialBuyPriceMapper extends BaseMapper<MaterialBuyPrice> {

    /**
     * 详情
     * @param id
     * @return
     */
    MaterialBuyPriceVo findById(String id);

    /**
     * 列表
     * @param params
     * @return
     */
    List<MaterialBuyPriceVo> findAllList(@Param("params") MaterialBuyPriceSearchParam params);
    /**
     * 列表
     * @param params
     * @return
     */
    List<MaterialBuyPriceVo> findAll(@Param("params") MaterialBuyPriceSearchParam params);
    List<MaterialBuyPriceVo> getByMapId(@Param("id") String id);
    /**
     * 分页
     * @param page
     * @param params
     * @return
     */
    IPage<MaterialBuyPriceVo> findAll(Page page, @Param("params") MaterialBuyPriceSearchParam params);
    /**
     * 分页
     * @param page
     * @param params
     * @return
     */
    IPage<MaterialBuyPriceVo> findAllList(Page page, @Param("params") MaterialBuyPriceSearchParam params);
    List<MaterialBuyPriceVo> findPriceBySku(@Param("custSkuId") String custSkuId);
}
